<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>管理后台</title>
<link rel="stylesheet" type="text/css" href="template/admin.css"/>
<script type="text/javascript" src="template/images/jquery.js"></script>
<script type="text/javascript" src="template/images/admin.js"></script>
<script type="text/javascript">
$(document).ready(function(){
	$('#ifram_main').attr("src","<?php echo $iframe_url;?>"); 
	$('.admin_small_nav').find('li').find('span').toggle(function(){
		$(this).next('div').hide();
		$(this).addClass('on');
	},function(){
		$(this).next('div').show();
		$(this).removeClass('on');
	});
	//alert($(document.body).height());//浏览器当前窗口文档body的高度
});
</script>
<style type="text/css">
body{
overflow-x:hidden;
overflow-y:hidden;
}
</style>
</head>

<body scroll="no">

<table width="100%" height="100%" cellpadding="0" cellspacing="0" style="width:100%">
	<tbody>
		<tr>
			<td colspan="2" height="66">
			<div class="admin_head">
				<table width="100%" height="100%" cellpadding="0" cellspacing="0">
					<tbody>
						<tr>
							<td width="177">
									
	<div class="admin_logo"><img src="template/images/logo.gif" border="0"/></div>
							</td>
							<td width="100%">
								<div class="admin_head_rigt">
		<div class="admin_info">
		管理员<label><?php echo $rel[0]['admin_name'];?></label>欢迎回来</span><span>上次登陆时间:<label style="font-weight:normal"><?php echo empty($rel[0]['admin_time'])?'':date('Y-m-d H:m:s',$rel[0]['admin_time']);?></label></span><span>上次登陆IP:<label style="font-weight:normal"><?php echo $rel[0]['admin_ip']; unset($rel);?></label></span><span>本次登陆IP:<label style="font-weight:normal"><?php echo get_ip();?></label><label style="font-weight:bold; padding-left:8px;"><a href="http://fsai.cn/htm/jzfw-cn/" target="_blank" style="padding-right:5px; color:#fff">网站建设</a><a href="http://fsai.cn/htm/jzfw-cn/" target="_blank" style="padding-right:5px; color:#fff">模板制作</a><a href="http://fsai.cn/htm/sqsm/" target="_blank" style="padding-right:5px; color:#fff">授权服务</a></label>
		</div><!--登录的一些信息-->
		<div class="admin_head_nav">
			<ul class="main_nav">
				<?php
				if(!empty($admin_main_nav)){
				foreach($admin_main_nav as $v){
				?>
				<li><a <?php if($main_nav==$v['main_nav']){echo 'class="focus"';}?> href="?main_nav=<?php echo $v['main_nav'];?>"><?php echo $v['name'];?></a></li>
				<?php
				}
				}
				?>
			</ul>
			<ul class="out_nav">
				<li><a href="admin_cache.php?action=del_cache_file">清除缓存</a></li>
				<li><a href="../index.php" target="_blank">网站主页</a></li>
				<li><a href="http://fsai.cn" target="_blank">官网首页</a></li>
				<li><a href="login.php?action=out">退出登录</a></li>
			</ul>
			<div class="clear"></div>
		</div><!--主导航-->
	</div>
	<div class="clear"></div>	
							</td>
						</tr>
					</tbody>
				</table>
	
</div><!--顶部-->
			</td>
		</tr>
		<tr>
			<td width="180" style="background:#EAF2FB"  valign="top">
			
				<div class="admin_contain_left">
		<div class="admin_time2">
		<span style="padding-left:8px;" id=localtime></span>
<script type="text/javascript">
function showLocale(objD)
{
	var str,colorhead,colorfoot;
	var yy = objD.getYear();
	if(yy<1900) yy = yy+1900;
	var MM = objD.getMonth()+1;
	if(MM<10) MM = '0' + MM;
	var dd = objD.getDate();
	if(dd<10) dd = '0' + dd;
	var hh = objD.getHours();
	if(hh<10) hh = '0' + hh;
	var mm = objD.getMinutes();
	if(mm<10) mm = '0' + mm;
	var ss = objD.getSeconds();
	if(ss<10) ss = '0' + ss;
	var ww = objD.getDay();
	colorhead="<font color=\"#fff\">";
	if  (ww==0)  ww="星期日";
	if  (ww==1)  ww="星期一";
	if  (ww==2)  ww="星期二";
	if  (ww==3)  ww="星期三";
	if  (ww==4)  ww="星期四";
	if  (ww==5)  ww="星期五";
	if  (ww==6)  ww="星期六";
	colorfoot="</font>"
	str = colorhead + yy + "-" + MM + "-" + dd + " " + hh + ":" + mm + ":" + ss + "  " + ww + colorfoot;
	return(str);
}
function tick()
{
	var today;
	today = new Date();
	document.getElementById("localtime").innerHTML = showLocale(today);
	window.setTimeout("tick()", 1000);
}
tick();
</script>
		</div>
		<div class="admin_small_nav">
			<ul>
			<?php
			if(!empty($c_arr)){
				foreach($c_arr as $v){
			?>
			
			<li class="top">
				<span><?php echo $v['channel_name'];?></span>
				<div id="child">
				<p><a <?php if($model==$v['channel_mark']&&$act=='add'){echo 'class="focus"';}?> href="?main_nav=<?php echo $main_nav;?>&act=add&model=<?php echo $v['channel_mark'];?>&channel_id=<?php echo $v['id'];?> ">添加内容</a></p>
				<p><a <?php if($model==$v['channel_mark']&&$act=='list'){echo 'class="focus"';}?> href="?main_nav=<?php echo $main_nav;?>&act=list&model=<?php echo $v['channel_mark'];?>&channel_id=<?php echo $v['id'];?> ">管理内容</a></p>
				</div>
			</li>
			
			<?php
				}
			}
			if($main_nav=='content'){
			?>
			<li class="top">
				<span>单页内容</span>
				<div id="child">
				<p><a <?php if($model=='alone'){echo 'class="focus"';}?> href="?main_nav=<?php echo $main_nav;?>&model=alone ">单页内容管理</a></p>
				</div>
			</li>
			<?php
			}
			if(!empty($admin_left_nav[$main_nav])){
			foreach($admin_left_nav[$main_nav] as $v){
			?>
				<?php if($v['child']){?>
				<li class="top">
				<span><?php echo $v['name'];?></span>
				<div id="child">
				<?php 
				foreach($v['child'] as $child_v){
				?>
				<p><a <?php if($left_nav==$child_v['left_nav']){echo 'class="focus"';}?> href="?main_nav=<?php echo $main_nav;?>&parent_nav=<?php echo $v['left_nav'];?>&left_nav=<?php echo $child_v['left_nav'];?>"><?php echo $child_v['name'];?></a></p>
				<?php
				}
				echo "</div></li>";
				}else{?>
				<li><a <?php if($left_nav==$v['left_nav']){echo 'class="focus"';}?> href="?main_nav=<?php echo $main_nav;?>&parent_nav=<?php echo $v['left_nav'];?>&left_nav=<?php echo $v['left_nav'];?>"><?php echo $v['name'];?></a></li>
				<?php
				}
				?>
			<?php
			}
			}
			?>	
			</ul>
		</div>
	</div><!--左边-->
				
			</td>
			<td width="100%" valign="top">
		<iframe scrolling="yes" frameborder="0" height="580" style="overflow:visible;" width="100%" name="main" id="ifram_main"></iframe>
			</td>
		</tr>
	</tbody>
</table>
</body>
</html>